package com.hc.action;

import io.seata.rm.tcc.api.BusinessActionContext;
import io.seata.rm.tcc.api.BusinessActionContextParameter;
import io.seata.rm.tcc.api.TwoPhaseBusinessAction;

public interface GoodAction {
    @TwoPhaseBusinessAction(name = "tcc-good")
    public void tryGood(BusinessActionContext context,
                        @BusinessActionContextParameter("goodId") int goodId,
                        @BusinessActionContextParameter("num") int num);


    public void commit(BusinessActionContext context);


    public void rollback(BusinessActionContext context);
}
